package com.grace.cms.forum.user.controller.api;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import com.grace.cms.forum.record.service.impl.CmsRecordServiceImpl;
import com.grace.cms.general.controller.CommonController;
import com.grace.common.config.GraceConfig;
import com.grace.common.core.domain.AjaxResult;

@RestController
@RequestMapping
public class RecoedApiController extends CommonController {

    @Autowired
    private CmsRecordServiceImpl recordService;
    @GetMapping("/{themeName}/api/record/getCmsRecordVo/{recordId}/{createBy}")
    public AjaxResult selectCmsRecordVo(@PathVariable("themeName")String themeName,@PathVariable("recordId") String recordId,@PathVariable("createBy") String createBy){
        return success(recordService.selectCmsRecordVo(recordId,createBy,themeName,GraceConfig.getOnlyCode())); 
    }
}
